package edu.neusoft.android.yuejian14.activity;

import android.os.Bundle;
import android.support.v7.app.AppCompatActivity;
import android.view.View;

import edu.neusoft.android.yuejian14.R;


public abstract class BaseActivity extends AppCompatActivity {
    protected int layout_file= R.layout.activity_main;
    protected static int uid;
    abstract void initViews();

    abstract View initViews(View view);
    abstract void initEvents();
    abstract void initData();
    void setLayout(int layout_file)
    {
        setContentView(layout_file);
    }

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.train_detail);
        //隐藏系统标题栏
        setLayout(layout_file);
        initViews();
        initEvents();
        initData();
    }


//    public void onViewCreated(View view, Bundle savedInstanceState) {
//
//    }

//    public void setUid(int uid){
//        uid=uid;
//    }

    public static int getUid(){

        return uid;
    }

}
